-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add serializers for bulk license enrollment endpoint #567
feat: add serializers for bulk license enrollment endpoint #567
Conversation
@extend_schema( | ||
parameters=[ | ||
serializers.EnterpriseEnrollmentWithLicenseSubsidyQueryParamsSerializer, | ||
], | ||
request=serializers.EnterpriseEnrollmentWithLicenseSubsidyRequestSerializer, | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice! Consider copoying some of the docs below about expected params into the help_text
of your new serializer fields.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@iloveagent57 added the help_text
field to serializer fields.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One other thing you might want to consider is refactoring the validation logic out of _validate_enrollment_request_params()
and into the validation of your new serializer classes (could be a follow-up PR).
11a28df
to
4ea89b0
Compare
@iloveagent57 the serializer validators follow a specific format for their errors, therefore, any changes to them must be tested and adjusted in the |
Description
Created serializers for the POST
bulk-license-enrollment
endpoint to enable query params and request body.Link to the associated ticket: https://2u-internal.atlassian.net/browse/ENT-8179
Please confirm if any field is out of scope or under the wrong validation.

Testing considerations
already been performed.
Post-review
Squash commits into discrete sets of changes